package com.wxit.limit.controller;

import com.wxit.limit.pojo.User;
import com.wxit.limit.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/api/user")
public class UserController {

    @Autowired
    private UserService userService;

    /**
     * 添加用户信息
     * @param user
     */
    @PostMapping
    public void save(User user) {
        //保存数据
        userService.save(user);
    }
}
